import BaseMonsterSkill from "./BaseMonsterSkill";
import IBaseMonsterSkill from "./IBaseMonsterSkill";
import MonsterScript from "../../../component/MonsterScript";


export default class ChangeMovePosSkill extends BaseMonsterSkill implements IBaseMonsterSkill {


    _originPos: Laya.Vector3[] = [];
    

    init(target: MonsterScript, skillId) {
        super.init(target, skillId);
        Object.assign(this._originPos, this._target.movePos);
        // console.log(this._originPos);
        if(!this._skillData.movePos){
            this._skillData.movePos=[new Laya.Vector3(3.5, 0, -13.5), new Laya.Vector3(3.5, 0, 7.5),
                new Laya.Vector3(-3.5, 0, 7.5), new Laya.Vector3(-3.5, 0, -13.5)];
        }
        for (let i = 0; i < this._target.movePos.length; i++) {
            this._target.movePos[i].x = this._skillData.movePos[i].x;
            this._target.movePos[i].y = this._skillData.movePos[i].y;
            this._target.movePos[i].z = this._skillData.movePos[i].z;
        }
    }

  
    exec() {


    }

    reset(){
        super.reset();
    }

 

}